<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html>
<head>
    <title>编辑biz</title>
    <%@ include file="../../common/meta.jsp" %>
    <link href="${ctx}/css/page/common-win.css?t=${now}" rel="stylesheet">
    <script src="${ctx}/js/plugins/validate/jquery.validate.custom.js?t=20181024"></script>
    <style>
        #_btnDiv{
            height: 34px;
            margin-bottom: 0px;
        }
    </style>
    <script>
        var editType = '${editType}';
        var searchParam = '${searchParam}';
        var oneBizInfo = ${oneBizInfo};
        var searchInfo = ${searchInfo};
    </script>
</head>
<body class="gray-bg">
<div>
    <div class="myContent">
        <div class="tabs-container">
            <div class="tab-content">
                <div id="tab-1" class="tab-pane active">
                    <div class="row">
                        <div class="col-sm-12">
                            <div class="ibox float-e-margins myIbox">
                                <div class="ibox-content">
                                    <h5 class="page-header page-header-new"><i class="fa fa-file-text"></i>&nbsp;&nbsp;${editType == 'edit' ? '编辑' : (editType == 'info' ? '详情' : '新增')}</h5>
                                    <form class="form-horizontal m-t" id="_bizDataForm">
                                        <c:choose>
                                            <c:when test="${editType=='info'}">
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">bizId：</label>
                                                    <label class="col-sm-8 control-label control-label-content">${not empty oneBizInfo ? oneBizInfo.bizId : ''}</label>
                                                </div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">名称：</label>
                                                    <label class="col-sm-8 control-label control-label-content">${not empty oneBizInfo ? oneBizInfo.name : ''}</label>
                                                </div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">seed：</label>
                                                    <label class="col-sm-3 control-label control-label-content">${not empty searchInfo ? searchInfo.seedName : ''}</label>
                                                    <label class="col-sm-2 control-label">排序：</label>
                                                    <label class="col-sm-3 control-label control-label-content">${not empty oneBizInfo ? oneBizInfo.sortNum : ''}</label>
                                                </div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">描述：</label>
                                                    <label class="col-sm-8 control-label control-label-content">${not empty oneBizInfo ? oneBizInfo.remark : ''}</label>
                                                </div>
                                            </c:when>
                                            <c:otherwise>
                                                <c:if test="${editType != 'add'}">
                                                    <div class="form-group">
                                                        <label class="col-sm-2 control-label">bizId：</label>
                                                        <label class="col-sm-8 control-label control-label-content">${not empty oneBizInfo ? oneBizInfo.bizId : ''}</label>
                                                    </div>
                                                </c:if>
                                                <c:if test="${editType == 'add'}">
                                                    <div class="form-group form-group-new">
                                                        <label class="col-sm-2 control-label"><span style="color: red">*</span>bizId：</label>
                                                        <div class="col-sm-8">
                                                            <input type="text" id="bizId" name="bizId" class="form-control" maxlength="512" required value="${not empty oneBizInfo ? oneBizInfo.bizId : ''}">
                                                            <span class="help-block m-b-none tip"></span>
                                                        </div>
                                                    </div>
                                                </c:if>
                                                <div class="form-group form-group-new">
                                                    <label class="col-sm-2 control-label"><span style="color: red">*</span>名称：</label>
                                                    <div class="col-sm-8">
                                                        <input type="text" id="name" name="name" class="form-control" maxlength="128" required value="${not empty oneBizInfo ? oneBizInfo.name : ''}">
                                                        <span class="help-block m-b-none tip"></span>
                                                    </div>
                                                </div>
                                                <div class="form-group form-group-new">
                                                    <label class="col-sm-2 control-label">seed：</label>
                                                    <label class="col-sm-3 control-label control-label-content">${not empty searchInfo ? searchInfo.seedName : ''}</label>
                                                    <label class="col-sm-2 control-label">排序：</label>
                                                    <div class="col-sm-3">
                                                        <input type="text" id="sortNum" name="sortNum" class="form-control" maxlength="9" isPInteger="true" value="${not empty oneBizInfo ? oneBizInfo.sortNum : ''}">
                                                        <span class="help-block m-b-none tip"></span>
                                                    </div>
                                                </div>
                                                <div class="form-group form-group-new">
                                                    <label class="col-sm-2 control-label">描述：</label>
                                                    <div class="col-sm-8">
                                                        <textarea type="text" id="remark" name="remark" class="form-control" maxlength="100" placeholder="100字以内" style="height: 80px; resize: none;">${not empty oneBizInfo ? oneBizInfo.remark : ''}</textarea>
                                                        <span class="help-block m-b-none tip"></span>
                                                    </div>
                                                </div>
                                            </c:otherwise>
                                        </c:choose>
                                    </form>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <div class="ibox float-e-margins">
            <div class="ibox-content">
                <div class="form-group" id="_btnDiv">
                    <div class="col-sm-4 col-sm-offset-5">
                        <c:if test="${editType!='info'}">
                            <input type="button" class="btn btn-primary" onclick="doBizSave()" value="保存">
                        </c:if>
                        <input type="button" class="btn btn-white" onclick="doCheckDataChange()" value="返回">
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<script src="${ctx}/js/stat/win/editBizMgr.js?t=${now}"></script>
</body>
</html>

